Numpy uses a custom boolean type which differs from the base bool type. We investigate and share some ways in which this can bug your code.
Implementing a Simple Anomaly Detection Algorithm in Python for Discrete and Continous Time Series